package agency.web.app.domain;

import java.util.List;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.JoinTable;
import javax.persistence.ManyToMany;
import javax.persistence.Table;


@Entity
public class ExcursionTour extends AbstractTour {
	
	@ManyToMany(targetEntity = Plan.class, fetch = FetchType.EAGER)
	@JoinTable(name = "tour_has_plan", joinColumns = { @JoinColumn(name = "TOUR_ID") }, inverseJoinColumns = { @JoinColumn(name = "PLAN_ID") })
	private List<Plan> excursionsList;
	
	public ExcursionTour(List<Country> country, String region, int price, String hotel, String transport, boolean hot, List<Trip> trips) {
		super(country, region, price, hotel, transport, hot, trips);
		
	}

	public List<Plan> getExcursionsList() {
		return excursionsList;
	}

	public void setExcursionsList(List<Plan> excursionsList) {
		this.excursionsList = excursionsList;
	}


}
